import axios from 'axios';

const api = {
  login(params: LoginParams): any {
    return axios.post('/login', params);
  },
  getUser(): any {
    return axios.get('/user');
  },
  getMenus(): any {
    return axios.get('/menus');
  },

  insertUser(params) {
    return axios.post('/user', params);
  },
  insertMenu(params) {
    return axios.post('/menu', params);
  },
  getUsers(params) {
    return axios.post('/users', params);
  },
};

export default api;
